<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
	</head>
	<body>
		<script>
			
			var a = 10;
			console. log("a="+a);
			function foo1()
			{
				console.log("foo1()a="+a);
				//a = 20 //
				var a = 30; //
				console.log("foo1()a="+a);
				var b = 50;
			}
			foo1();
			
			console.log("a="+a);
			console.log("b="+b);
		</script>
	</body>
</html>
